using System;
using System.Collections.Generic;
using System.Text;

namespace Serialcoder.Erp.Tools.PatchCreator.Runtime
{
    public class Patch : System.ComponentModel.INotifyPropertyChanged
    {
        private int m_Id;

        [System.ComponentModel.Bindable(true)]
        public int Id
        {
            get { return m_Id; }
            set
            {
                if (m_Id != value)
                {
                    m_Id = value;
                    OnPropertyChanged("Id");
                }
             }
        }

        private string m_Author;

        [System.ComponentModel.Bindable(true)]
        public string Author
        {
            get { return m_Author; }
            set
            {
                if (m_Author != value)
                {
                    m_Author = value;
                    OnPropertyChanged("Author");
                }
            }
        }

        private string m_Description;

        [System.ComponentModel.Bindable(true)]
        public string Description
        {
            get { return m_Description; }
            set
            {
                if (m_Description != value)
                {
                    m_Description = value;
                    OnPropertyChanged("Description");
                }
            }
        }

        private string m_Sql;

        [System.ComponentModel.Bindable(true)]
        public string Sql
        {
            get { return m_Sql; }
            set
            {
                if (m_Sql != value)
                {
                    m_Sql = value;
                    OnPropertyChanged("Sql");
                }
            }
        }

        private DateTime m_CreationDate;

        [System.ComponentModel.Bindable(true)]
        public DateTime CreationDate
        {
            get { return m_CreationDate; }
            set
            {
                if (m_CreationDate != value)
                {
                    m_CreationDate = value;
                    OnPropertyChanged("CreationDate");
                }
               
            }
        }

        #region INotifyPropertyChanged Membres

        public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;

        private void OnPropertyChanged(string propertyName)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
            }
        }

        #endregion
    }
}
